package roma.home.pages;

import org.openqa.selenium.WebDriver;
import org.testng.Assert;

import roma.home.data.ConstantData;

public class AbstractPage {
	
	protected WebDriver driver;
	
	public AbstractPage (WebDriver driver) {
		this.driver = driver;
	}
	
	public O1HomePage loadHomePage() {
		driver.navigate().to(ConstantData.HOME_URL);
		return new O1HomePage(driver);
	}
	
	public void checkTitle(String expText) {
		String actText = driver.getTitle();
		Assert.assertEquals(actText, expText);
	}

}
